package com.fable.sp.core.template;

import java.io.Writer;
import java.util.Map;

/**
 * .
 *
 * @author stormning on 16/8/5.
 */
public interface TemplateRenderer {

    String renderNamedTemplate(String name, Map<String, Object> params) throws TemplateNotFoundException, TemplateRenderException, TemplateNotFoundException;

    void renderNamedTemplate(String name, Map<String, Object> params, Writer writer) throws TemplateRenderException, TemplateNotFoundException;

    String renderStringTemplate(String fragment, Map<String, Object> params) throws TemplateRenderException, TemplateNotFoundException;

    void renderStringTemplate(String name, Map<String, Object> params, Writer writer) throws TemplateRenderException, TemplateNotFoundException;
}
